package priv.yiyuan.example.design.visitor;

/**
 * 元素实现类：数据库配置
 *
 * @author YiYuan
 * @data 2025/8/4
 * @apoNote
 */
public class DatabaseConfig implements ConfigurationElement {

    private String url;

    private String username;

    public DatabaseConfig(String url, String username) {
        this.url = url;
        this.username = username;
    }

    public String getUrl() {
        return url;
    }

    public String getUsername() {
        return username;
    }

    @Override
    public void accept(ConfigurationVisitor visitor) {
        visitor.visit(this);
    }
}
